1. Field of the Invention
The present invention relates generally to Network Interface Cards, and more particularly, to a method and apparatus for off-loading a checksum calculation to a Network Interface Card.
2. Description of the Related Art
A Network Interface Card (NIC) is a hardware device that allows a computer to communicate over a network. A NIC is installed on the computer and controlled by software known as a NIC driver which is loaded into memory by the computer""s operating system. A NIC driver is typically supplied by either the manufacturer of the NIC or by a third party, and is written to comply with the requirements of the operating system of the computer on which it will be used.
A NIC driver performs low level networking tasks specific to the NIC hardware in support of other software drivers known as protocols (also referred to as protocol drivers or transport drivers) which perform higher level networking functions. Some examples of commonly used protocols are Transmission Control Protocol/Internet Protocol (TCP/IP), NetBIOS Extended User Interface (NetBEUI, where NetBIOS refers to Network Basic Input/Output Specification), and Internet Packet Exchange/Sequenced Packet Exchange (IPX/SPX).
The Microsoft Windows NT 4.0 operating system includes a driver interface known as Network Driver Interface Specification version 4.0 (NDIS 4.0) through which NIC drivers communicate with protocols, the operating system, and one or more NICs. NDIS forms what is known as a xe2x80x9cwrapperxe2x80x9d around NIC drivers to abstract the NIC driver from hardware and protocols. This improves the portability of the driver code. NDIS also provides a library of routines which NIC drivers can use to perform many standardized networking tasks, thereby making it easier to create NIC drivers.
In NDIS 4.0, protocol drivers such as TCP/IP drivers must perform layer 4 (TCP) and layer 3 (IP) checksum validation. A newer version of NDIS (sometimes referred to as NDIS 5.0) is included in the Microsoft Windows 2000 operating system. NDIS in Windows 2000 retains the basic requirements, services and architecture of earlier versions, but also provides procedures for off-loading certain tasks to a NIC. One such off-loadable task is the validation of layer 3 and 4 (e.g., TCP/IP) checksums.
In accordance with the present invention, a hardware assisted checksum is calculated for an indiscriminate region of a packet.